{% extends "admin/base_site.html" %}
{% load i18n static extra_functions %}


{% block breadcrumbs %}
<div class="breadcrumbs">
<a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
&rsaquo; {% trans 'Password change' %}
</div>
{% endblock %}


<div class="row">
<div class="col-md-12">
<div class="box box-primary">
    
{% block title %}{{ title }}{% endblock %}
{% block content_title %}<h1>{{ title }}</h1>{% endblock %}

{% block content %}<div id="content-main">
<div class="box box-info">
<form method="post" class="form-horizontal">{% csrf_token %}
<div class="box-body">
{% if form.errors %}
    <p class="text-red">
    {% if form.errors.items|length == 1 %}{% trans "Please correct the error be0low." %}{% else %}{% trans "Please correct the errors below." %}{% endif %}
    </p>
{% endif %}


<p>{% trans "Please enter your old password, for security's sake, and then enter your new password twice so we can verify you typed it in correctly." %}</p>



<div class="form-group">
    
    <label class="col-sm-2 control-label" for={{form.old_password.name}}>{{form.old_password.label}}</label>
    <div class="col-sm-10">
        {{ form.old_password|add_class:"form-control" }}  
        {{ form.old_password|get_erro_field }}  
    </div>
</div>

<div class="form-group">
    
    <label class="col-sm-2 control-label" for={{form.new_password1.name}}>
        {{form.new_password1.label}}
    </label>
    <div class="col-sm-10">
        {{ form.new_password1|add_class:"form-control" }}
        {{ form.new_password1|get_erro_field }}
    </div>
    {% if form.new_password1.help_text %}
    <p class="help-block">{{ form.new_password1.help_text|safe }}</p>
    
    {% endif %}
</div>

<div class="form-group">

    <label class="col-sm-2 control-label" for={{form.new_password2.name}}>{{form.new_password2.label}}</label>
    <div class="col-sm-10">
        {{ form.new_password2|add_class:"form-control" }}
        {{ form.new_password2|get_erro_field }}
        {% if form.new_password2.help_text %}
            <p class="help-block">{{ form.new_password2.help_text|safe }}</p>
        {% endif %}
    </div>
    
</div>


</div>
<div class="box-footer">
    <input type="submit" value="{% trans 'Change my password' %}" class="btn btn-info pull-right" />
</div>

</form></div></div>
</div>
</div>
</div>

{% endblock %}
